<!doctype html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
<!-- Apple devices fullscreen -->
<meta name="apple-mobile-web-app-capable" content="yes">
<!-- Apple devices fullscreen -->
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
<link rel="shortcut icon" type="image/x-icon" href="__ROOT_DIR__/favicon.ico" media="screen"/>
<title>{$global.web_name|default=''}-{notempty name="$is_eyou_authortoken"}易优CMS企业网站管理系统{/notempty}{$version}</title>
<script type="text/javascript">
    var eyou_basefile = "{$Request.baseFile}";
    var module_name = "{$Think.const.MODULE_NAME}";
    var SITEURL = window.location.host + eyou_basefile + "/" + module_name;
    var GetUploadify_url = "{:url('Uploadimgnew/upload')}";
    // 插件专用旧版上传图片框
    if ('Weapp@execute' == "{$Think.const.CONTROLLER_NAME}@{$Think.const.ACTION_NAME}") {
      GetUploadify_url = "{:url('Uploadify/upload')}";
    }
    var __root_dir__ = "__ROOT_DIR__";
    var __lang__ = "{$admin_lang}";
    var VarSecurityPatch = "{$security_patch|default='0'}";
</script>

<link href="__SKIN__/css/main.css?v={$version}" rel="stylesheet" type="text/css">
<link href="__SKIN__/js/jquery-ui/jquery-ui.min.css" rel="stylesheet" type="text/css">
<link href="__SKIN__/font/css/font-awesome.min.css" rel="stylesheet" />
<link href="__SKIN__/font/css/iconfont.css?v={$version}" rel="stylesheet" />
<link href="__SKIN__/css/diy_style.css?v={$version}" rel="stylesheet" type="text/css" />
{include file="public/theme_css" /}
<script type="text/javascript" src="__SKIN__/js/jquery.js"></script>
<script type="text/javascript" src="__SKIN__/js/common.js?v={$version}"></script>
<script type="text/javascript" src="__SKIN__/js/jquery-ui/jquery-ui.min.js"></script>
<script type="text/javascript" src="__SKIN__/js/jquery.cookie.js"></script>
<script type="text/javascript" src="__SKIN__/js/jquery.bgColorSelector.js"></script>
<script type="text/javascript" src="__SKIN__/js/admincp.js?v={$version}0"></script>
<script type="text/javascript" src="__SKIN__/js/jquery.validation.min.js"></script>

<!-- <script type="text/javascript" src="__PUBLIC__/plugins/layer/layer.js"></script> -->
<script type="text/javascript" src="__PUBLIC__/plugins/layer-v3.1.0/layer.js?v={$version}"></script>
<script type="text/javascript" src="__SKIN__/js/dialog/dialog.js?v={$version}" id="dialog_js"></script>
<script src="__SKIN__/js/upgrade.js?v={$version}"></script>
<script src="__SKIN__/js/global.js?v={$version}"></script>
</head>
<body>
{include file="public/menubox" /}
<style>
.scroll-wrapper {   
  height: 100%;
  -webkit-overflow-scrolling: touch;   
  overflow-y: auto;   
} 
</style>
<div class="admincp-container unfold">
{include file="public/left" /}
  <div class="admincp-container-right">
    <div class="admincp-header">
      <div class="wraper">
        <div class="bgSelector"></div>
        <div id="foldSidebar"><i class="fa fa-bars"  title="展开/收起侧边导航"></i></div>
        <div class="admincp-name" id="foldSidebar2">
        </div>
        <div class="admincp-header-r">
          <div class="manager">
            <dl>
              <dt class="name">{$admin_info.user_name}</dt>
              <dd class="group">{$admin_info.role_name}</dd>
            </dl>
            <div class="btn-group pull-left ey-tool">

              <a class="btn btn-default dropdown-toggle" target="_blank" href="{$home_url}">
                <i class="fa fa-desktop"></i>
                <span class="hidden-xs">网站首页</span>
              </a>

              {eq name="'System@clear_cache'|is_check_access" value="1"}
                <a class="btn btn-default dropdown-toggle" href="javascript:void(0);" onclick="clear_cache();">
                  <i class="fa fa-refresh"></i>
                  <span class="hidden-xs">清除缓存</span>
                </a>
              {/eq}
              
              {notempty name="$is_eyou_authortoken"}
              <!-- 商业授权 -->   
              <em class="eyou_tool em_authortoken" data-expanded="close">
                <a class="btn btn-default dropdown-toggle" href="javascript:void(0);" onclick="valide(this);">
                  <i class="fa fa-bookmark"></i>
                  <span class="hidden-xs">购买授权</span>
                </a>
                <ul class="dropdown-menu" role="menu" aria-labelledby="shouquan">
                    <li class="ey-tool-list text-center"><a target="_blank" class="liaojie" href="https://www.eyoucms.com/buy/"  title="购买后可去除所有版权提示">了解商业授权</a></li>
                    <li class="ey-tool-list text-center">
                      <input class="btn btn-primary" type="button" onclick="$('.em_authortoken').toggleClass('open');openItem('Index|authortoken');" value="检测是否正版" />
                    </li>
                </ul>
               </em>
              <!-- 商业授权 -->   
              {/notempty}

              <!-- 多语言 -->
              {if condition="$php_servicemeal >= 1 || !empty($global.system_use_language)"}
              <em id="Language_index" class="eyou_tool em_lang" data-expanded="close" {if condition='empty($web_language_switch) || !empty($global.web_citysite_open)'}style="display: none;"{/if}>
                <a class="btn btn-default dropdown-toggle" title="支持多语言切换" href="javascript:void(0);" onclick="valide(this);">
                  <i class="fa fa-globe"></i>
                  <span class="hidden-xs" id="language_title">{$languages[$admin_lang]['title']|default='简体中文'}</span>
                </a>
                <ul class="dropdown-menu" role="menu" aria-labelledby="shouquan">
                  {volist name='languages' id='vo'}
                    <li class="ey-tool-list text-center lang"><a class="liaojie" href="?lang={$vo.mark}">{$vo.title}</a></li>
                  {/volist}
                    <li class="ey-tool-list text-center" id="addlang">
                      <button class="btn btn-primary" type="button" onclick="$('.em_lang').toggleClass('open');openItem('Language|index');" /><i class="fa fa-globe"></i>&nbsp;多语言设置</button>
                    </li>
                </ul>
               </em>
              {/if}
              <!-- 多语言 -->   

              <!-- 小程序 start --> 
              {eq name="'Diyminipro@page_edit'|is_check_access" value="1"}
              <a id="Diyminipro_theme_index" class="btn btn-default dropdown-toggle" href="{:url('Diyminipro/page_edit')}" target="_blank" {if condition='$web_diyminipro_switch == -1'} style="display: none;" {/if} title="可视化小程序">
                <i class="fa fa-compass"></i>
                <span class="hidden-xs">小程序</span>
              </a>
              {/eq}
              <!-- 小程序 end --> 

              <!-- 服务器升级 -->
              {empty name="$security_patch"}
                {eq name="upgrade" value="true"}
                <div id="upgrade_filelist" style="display:none;"></div> 
                <div id="upgrade_intro" style="display:none;"></div> 
                <div id="upgrade_notice" style="display:none;"></div> 
                <a class="btn btn-default dropdown-toggle" style="display: none;color:#F00;" title="不升级可能有安全隐患" href="javascript:void(0);" id="a_upgrade" data-version="" data-max_version="" data-iframe="parent" data-tips_url="{:url('Upgrade/setPopupUpgrade')}" data-upgrade_url="{:url('Upgrade/OneKeyUpgrade')}" data-check_authority="{:url('Upgrade/check_authority')}">
                  <i class="fa fa-info-circle"></i>
                  <span class="hidden-xs">系统更新</span>
                </a>
                {/eq}
              {/empty}
              <!-- 服务器升级 end -->
            </div>
            
            <div class="admin_user_dropup">
              <div class="admin_user_dropup_bt">
                <img id="admin_head_pic" tptype="admin_avatar" src="{$admin_info.head_pic|get_head_pic=###,true}" style="cursor: pointer;width: 34px;height: 34px;">
                <i class="fa fa-angle-down" aria-hidden="true"></i>
                {empty name="$is_eyou_authortoken"}
                <span class="info-num UnreadNotify1615518028 {empty name='$notice_count'}none{/empty}">{$notice_count}</span>
                {/empty}
              </div>
              <div class="admin_user_dropup_con">
                <ul>
                  <li><a href="javascript:void(0);" onclick="openItem('Admin|admin_edit|id|{$admin_info['admin_id']}');">个人信息</a></li>
                  <li><a href="javascript:void(0);" data-href="{:url('Encodes/theme_conf')}" onclick="openFullframe(this, '皮肤设置', '80%', '80%');">皮肤设置</a></li>
                  {empty name="$is_eyou_authortoken"}
                  <li><a href="javascript:void(0);" onclick="openItem('UsersNotice|admin_notice_index');">站内通知</a><span class="info-num UnreadNotify1615518028 {empty name='$notice_count'}none{/empty}">{$notice_count}</span></li>
                  {/empty}
                  <li><a href="{:url('Admin/logout')}">安全退出</a></li>
                </ul>
              </div>
            </div>
            <script type="text/javascript">
              $(".admin_user_dropup").mouseover(function(){
                 $(".admin_user_dropup_con").show();
                 $(".admin_user_dropup_bt").children('i').removeClass('fa-angle-down').addClass('fa-angle-up');
              });
              $(".admin_user_dropup").mouseout(function(){
                 $(".admin_user_dropup_con").hide();
                 $(".admin_user_dropup_bt").children('i').removeClass('fa-angle-up').addClass('fa-angle-down');
              });
            </script>
            
          </div>
        </div>
        <div class="clear"></div>
      </div>
    </div>
    <div class="top-border"></div>
    <div class="scroll-wrapper">
      <iframe src="{:url('Index/welcome')}" id="workspace" name="workspace" style="overflow-y: auto" frameborder="0" width="100%" height="95%" scrolling="yes" onload="window.parent"></iframe>
      <script type="text/javascript">ajax_system_1610425892();</script>
    </div>
  </div>
</div>
<script type="text/javascript">

  $(function() {
      /* 定时查询未读的站内信 --- 暂定为60秒查询一次 */
      var is_author = {$is_eyou_authortoken|default='0'};
      if (is_author == 0) {
          window.setInterval(UnreadNotify1615518028, 1*60*1000);
      }
      function UnreadNotify1615518028() {
        $.ajax({
            url : "{:url('Notify/count_unread_notify')}",
            type: 'post',
            data: {'_ajax': 1},
            dataType: 'JSON',
            success: function(res) {
                if (1 == res.code) {
                  $('.UnreadNotify1615518028').empty().html(res.data.notice_count);
                }
            }
        });
      }

      // 轮询更新sitemap.html网站地图
      function UpdateSitemap1647228884(){
          $.ajax({
              url : "{:url('Sitemap/ajax_update_sitemap_html')}",
              type: 'post',
              data: {'_ajax': 1},
              dataType: 'JSON',
              success: function(res) {

              }
          });
      }
      var sitemap_html = {$global['sitemap_html']|default=0};
      if (1 == sitemap_html) {
          window.setInterval(UpdateSitemap1647228884, 2*60*1000);
      }
  });
  /* END */

  function valide(obj)
  {
    var cls = $(obj).parent().attr('class');
    $('.eyou_tool').removeClass('open');
    if(cls.indexOf("open") > 0) {
      $(obj).parent().addClass('open');
    }
    $(obj).parent().toggleClass('open');
  }

  // 清除缓存
  function clear_cache()
  {
      layer_loading('正在清除');
      $.ajax({
          url: "{:url('System/clear_cache', ['_ajax'=>1])}",
          type: 'post',
          dataType: 'JSON',
          data: {clearall: 1},
          success: function(res){
              layer.closeAll();
              if (res.code == 1) {
                  layer.msg(res.msg, {time:1000}, function(){
                    top.window.location.reload();
                  });
              } else {
                  showErrorMsg(res.msg);
              }
          },
          error: function(e){
              showErrorMsg(e.responseText);
          }
      });
  }
</script>
</body>
</html>